<%@page import="com.fractalist.base.core.constants.SystemConstants"%>
<%@page import="java.net.URLEncoder"%>
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ include file="/common/includes.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<base href="${ctx}/" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>欢迎使用</title>
<link href="${ctx}/css/main_base.css" rel="stylesheet" type="text/css" />
<link href="${ctx}/css/main_style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="${ctx}/js/jquery-1.6.1.min.js"></script>
<script type="text/javascript" src="${ctx}/js/jquery.simplemodal.js"></script>
<script type="text/javascript">
	var tags = [];
	var tmp1 = {
		tagId : 1
	};
	var tmp2 = {
			tagId : 2
		};
	tags.push(tmp1);
	tags.push(tmp2);

	function AryTransJson(name, dataAry) {
		var str = {};
		if (!dataAry || dataAry.length == 0)
			return str;
		for ( var i = 0; i < dataAry.length; i++) {
			var data = dataAry[i];
			for ( var d in data) {
				str[name + "[" + i + "]." + d] = data[d];
			}
		}
		return str;
	}

	function objExtend() {
		var str = {};
		var arglen = arguments.length;
		for ( var i = 0; i < arglen; i++) {
			var arg = arguments[i];
			if (arg) {
				for ( var o in arg) {
					str[o] = arg[o];
				}
			}
		}
		return str;
	}

	var data = objExtend(AryTransJson("tags", tags), {
		"imageId" : 10,
		"summary":"testsum"
	});

	$.ajax({
		type : "POST",
		url : "${ctx}/phone/SaveImage.action",
		data : {
			"tags" : tags,
			"imageId" : 10,
			"summary":"testsum"
		},
		success : function(data) {
			alert(data);
		}
	})
</script>
<style>
.popup_title {
	height: 27px;
	line-height: 27px;
	color: #fff;
	font-weight: bold;
	padding: 0 10px 0 10px;
	background: url(images/popup_title_bg.png) top left repeat-x;
}

.popup_title_text {
	height: 27px;
	line-height: 27px;
	float: left;
}

.popup_close {
	width: 15px;
	height: 15px;
	float: right;
	display: block;
	background: url(images/close.png) top left no-repeat;
	margin-top: 5px;
}

.popup_body {
	width: 450px;
	height: 230px;
	background: #F0F8FB;
}

.popup_content {
	padding: 20px;
	height: 110px;
}

.popup_buttons a {
	margin: 0 0 0 20px;
}

table td {
	line-height: 35px;
	padding-left: 5px;
}

.button {
	display: inline-block;
	width: 75px;
	height: 25px;
	line-height: 25px;
	background: url(images/button_bg.png) top left no-repeat;
	color: #205a82;
	text-align: center;
}

.tl {
	text-align: left;
}

.tc {
	text-align: center;
}

.tr {
	text-align: right;
}

.red {
	color: #c80000;
}

iframe {
	height: 100%;
	width: 100%;
	position: absolute;
	top: 0;
	left: 0;
}
</style>
</head>

<body>
</body>
</html>